The present claimed invention relates to the field of computer controlled graphics display systems. Specifically, the present claimed invention relates to an apparatus and a method for linearly filtering data using the phase angle of the texture data to render an interactive graphics display.
Computer controlled graphics systems are used for displaying graphics objects on a display screen. A graphics object is composed of graphics primitive elements (xe2x80x9cgraphics primitivesxe2x80x9d) that include points, lines, polygons, etc. that render a two-dimensional (2D) image of a three dimensional (3D) object on a display screen. Each graphics primitive element within the graphics object is represented by a data structure. By linking all the graphics primitive elements and their respective data structures, a linked data structure is stored in computer memory. Each graphics primitive in the geometrical model is, in turn, associated with the proper attributes to give it the desired color, texture, etc.
Prior Art FIG. 1A presents an illustration of texture maps 102a and 102b. Each of the two maps covers the xe2x80x98Xxe2x80x99 and xe2x80x98Yxe2x80x99 spatial dimension as indicated by the coordinate axes 104. Multiple texture maps 102a and 102b can be used to provide another aspect to texture data. Texture maps are used to create a more realistic looking 2D image of a 3D object by digitally xe2x80x98coveringxe2x80x99 the surface of an object with a texture. Texture map 102a is comprised of one or more texels, or tiles, e.g. 106. Texels are essentially a pixel with a texture attribute. In Prior Art FIG. 1, the tiles, a.k.a. texels, in the lower left corner of texture map 102a have been labeled t(0,0), t(0,1), t(1,0), and t(1,1) and of texture map 102b have been labeled with the primed equivalent. These texels usually represent a texture pattern (e.g. a texture having a constant, a pattern, a gradient, etc. appearance of color, intensity, etc.).
Referring now to Prior Art FIG. 1B, an illustration of a conventional display device 112 having a field to which a conventional texture map will be projected is presented. The texture of the tile is in the form of data that can be mathematically stretched, shrunk, or flexed to cover a given 2D or 3D object, e.g. the rectangular surface 112 projected on conventional display device 110. If the 2-dimensional texel map 102a from Prior Art FIG. 1 A was used to map rectangular surface 112 projected in conventional display device 110, then texel map 102a would have to be digitally stretched to cover the surface due to the difference in indexes, e.g. a 4xc3x974 matrix to an 8xc3x978 matrix.
The process of mapping a texture onto a geometry can be defined as a function that maps a texel (s,t) or a set of texels {(s0, t0), (s1, t1) . . . (sn, tn)} to a point (u,v) of the geometry. The function defining the resulting texture on the geometry f(u, v) is defined by, or equivalent to, a function that manipulates the texel values, g(s, t). There are three conventional functions, or xe2x80x98filters,xe2x80x99 that are typically used for mapping. The first is a xe2x80x98nearestxe2x80x99 filter, the second is a xe2x80x98linearxe2x80x99 filter, and the third is a xe2x80x98weightedxe2x80x99 filter. These three filters will be described below with an example. The example will stretch a 4xc3x974 texture into an 8xc3x978 image. The set of texels is made up of four points, using s, t={0, 1, 2, 3}, in two directions. The image to receive the texture is made up of eight points, using u, v={0, 1, 2, 3, 4, 5, 6, 7}, in two dimensions.
The first filter is a nearest filter. For a linear filter, the texels are scaled to the geometry in a mapping function similar to:
f(u)=floor (2*s)
f(v)=floor (2*0t)
T(u,v)=f(u,v)
The function T(u, v) represents the resulting texel color value at f(u, v). The mapping function described above is the nearest filter because only the texel point (s, t) closest to a given geometry point (u, v) is chosen as the texel value for the given geometry point.
In the second filter, the linear filter, the mapping function uses the four nearest texels, for a two-dimensional field, to obtained the resulting filtered texel. Thus, for example, one possible mapping function can be defined as:
f(u)=floor (2*s)
f(v)=floor (2*t)
      T    ⁡          (              u        ,        v            )        =                    f        ⁡                  (                      u            ,            v                    )                    +              f        ⁡                  (                      u            ,                          (                              v                +                1                            )                                )                    +              f        ⁡                  (                                    (                              u                +                1                            )                        ,            v                    )                    +              f        ⁡                  (                                    (                              u                +                1                            )                        ,                          (                              v                +                1                            )                                )                      4  
The mapping described by T(u, v) sums the four nearest texels, then divides by four to normalize the result.
In the third filter, the weighted filter, the mapping function applies a weighting function to the linear filter to bias the texel values depending on their relative closeness to the geometry point. Hence, the mapping function could be:
xe2x80x83T(u, v)=Fraction_of [(1xe2x88x92A)*T0 +A*T1]
where:
T0=Fraction_of [(1xe2x88x92A)*f(u, v)]+[A *f(u,(v+1))]
T1=Fraction_of [(1xe2x88x92A)*f((u+1), v)]+[A *f((u+1), (v+1))]
and where A=the weighted coefficient to be used. Note that this weighted filter function simplifies to the linear filter used above if A=0.5. The weighting function can be further refined by specifying different values for A, the weighting coefficient, for each equation of T0, T1 and T(u, v).
While all these prior art filters provide different functions for computing a resulting texel value from a set of texels, they are constrained to a rectangular coordinate system. However, some applications, such as ultrasound data, represent their texel values using a polar coordinate system. That is, the texel values represent the phase or angular position. For example, ultrasound data can measure echo amplitude, frequency and phase throughout an image. The phase and frequency changes are used to indicate motion and relative velocities. That is, the measured differences in phase and frequency is used to study, for example blood flow. In the example of medical ultrasound, motion or blood flow is assigned a color value that represents velocity and flow direction. More specifically, flow toward the transducer can be assigned , for example, the color red, with a shift toward yellow at higher velocities. Similarly, flow away from the transducer is assigned the color blue with a shift toward green for higher velocities. No motion or flow is assigned the color black. It is precisely this angular form of data that is inadequately filtered using rectangular coordinate system filter functions.
An exemplary prior art normalized scale 150 for attribute data is presented in prior art FIG. 1C. The normalized scale 150 necessarily has a range from 0.0 to 1.0. This figure illustrates the averaging method used in the conventional filters. In this example, if two texels being averaged from texture map 100 have values of 0.8 and 0.2, their weighted average will be somewhere between 0.2-0.8, and their simple average will be 0.5. Neither the weighted average nor the simple average will be between 0.0-0.2 or 0.8-1.0.
Likewise, if the two texels being averaged have values of 0.4 and 0.6, their weighted average will be somewhere between 0.4 and 0.6, and their simple average will be 0.5. Again, neither the weighted average nor the simple average for this set of numbers will be between 0.0-0.4 or 0.6-1.0. This is assuming that the attribute data has been normalized to a maximum value of 1. Unfortunately, with this form of averaging, the averaged value must always be greater than the smallest attribute value and less than the largest attribute value. Consequently, the averaged value can be drastically different than the two nearest values. For example, an averaged value of 0.5 is clearly very proximate to attribute values of 0.4 and 0.6. However, an averaged value of 0.5 is very distant from either attribute values of 0.1 and 0.9. That is, the average of 0.5 is located 0.4 units away from 0.1 and from 0.9 Additionally, if the data is digitized, then harmonic scales of the 0-1 scale essentially continue out from 1.0 to 2.0 to 3.0, etc. Hence, a need arises for a method to average, e.g. interpolate, a value that accounts for the phase of the digitized attribute data.
As mentioned, the medical field of cardiology uses ultrasound procedures to determine blood flow through a patient""s body. The ultrasound procedure uses a transmitter/receiver head that can detect speed of blood flow and direction of blood flow using Doppler-effect concepts. The ultrasound data is fed into a graphics machine and processed with texture mapping to create a visual image of the blood flow patterns for diagnosis. However, because of the normalization and phase of the ultrasound blood flow data, a need arises for a method of interpolating the texture mapping operation to account for the phase data.
In summary, a need exists for finding an average, or interpolated, value that accounts for the phase data. Furthermore, a need arises for a method of interpolating the texture mapping operation to account for the magnitude data and phase data. If these needs are met, then more accurate images may be obtained, more accurate diagnoses may follow using faster and less-expensive computer processing hardware and software.
The present invention provides a method and apparatus for a modified linear filter using the texture data as phase angle data to render an interactive graphics display.
Specifically, in one embodiment, the present invention recites a method for filtering attribute data onto a display pixel using a minimum phase-angle average. First, a display pixel location is received. Then, a first and a second attribute data value is received. Subsequently, a filtering calculation is performed for the first attribute data value to create a filtered first texel attribute data value such that the resulting difference between the filtered first attribute data value and the second attribute data value is not greater than approximately half the magnitude of the maximum attribute data value. Finally, an average is calculated using the filtered first attribute data value and the second attribute data value. The average will be the resultant attribute value assigned to the display pixel location. By using the steps in this method, the present invention filters the texture data as phase angle data to render more meaningful texture mapping.
In another embodiment, the present invention recites a method of filtering attribute data within a graphics region of a computer controlled graphics display system having a processor coupled to a bus, a display device coupled to the bus and a computer readable memory unit coupled to the bus. The method comprises several steps. First, a display pixel location is received. Then, a plurality of attribute-data texels that are spatially proximate to the display pixel location are selected. Subsequently an interim attribute-data value, equivalent to the minimum phase-angle simple average from the attribute data value of two of the plurality of texels selected, is determined. The previous step is repeated until all the texels have been utilized once to determine an attribute data value. Another step determines a post-interim attribute data value. The post-interim attribute data value is equivalent to the minimum phase-angle average of two of the interim attribute data values, if available. Then, the previous step is repeated until all interim attribute data values have been utilized once to determine a post-interim attribute data value. In the last step, a final attribute data value for the display pixel location is determined. The final attribute data value is equivalent to the minimum phase-angle average of the last two post-interim attribute-data values, if available.